﻿<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<!--[if lt IE 9]>
<script type="text/javascript" src="../Public/js/html5.js"></script>
<script type="text/javascript" src="../Public/js/respond.min.js"></script>
<script type="text/javascript" src="../Public/js/PIE_IE678.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="../Public/css/H-ui.css"/>
<link type="text/css" rel="stylesheet" href="../Public/css/H-ui.admin.css"/>
<link type="text/css" rel="stylesheet" href="../Public/font/font-awesome.min.css"/>
<!--[if IE 7]>
<link href="../Public/font/font-awesome-ie7.min.css" rel="stylesheet" type="text/css" />
<![endif]-->

<title>产品分类</title>
</head>
<body>
<nav class="Hui-breadcrumb"><i class="icon-home"></i> 首页 <span class="c-gray en">&gt;</span> 商品管理 <span class="c-gray en">&gt;</span> 分类列表 <a class="btn btn-success radius r mr-20" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="icon-refresh"></i></a></nav>
<div class="pd-20">

 <form action="" method="post" id="form1">
   <div class="panel panel-primary radius">
	<div class="panel-header">
    <span class="l"> <a href="#" class="btn btn-danger radius"><i class="icon-trash"></i> 批量删除</a></span>
	 &nbsp;&nbsp;    <a href="javascript:;" onClick="tianjia('{:U('Admin/Hotnew/addCategory')}','添加类别');" class="btn btn-success radius"><i class="icon-plus"></i>  添加类别</a>
    <span class="r c-black">共有数据：<strong>{:$pageCount}</strong> 条</span>
 </div>
	<div class="panel-body">
  <table class="table table-border table-bordered  radius table-striped table-hover" width="100%">
    <thead>

      <tr class="text-c">
        <th width="31" align="center"><input type="checkbox" name="" value=""></th>
        <th width="49" align="center">分类ID</th>
        <th width="388" align="center">分类名称</th>
        <th width="87" align="center">操作</th>
      </tr>
    </thead>
    <tbody>
	 <volist name="list" id="vo">
      <tr class="text-c">
        <td align="center"><input type="checkbox" value="{$vo.cid}" name="cid[]"></td>
         <td  class="text-l">{$vo.cid}</td>
        <td  class="text-l">{$vo.fullname}</td>
        <td align="center" class="f-14 admin-manage"><a title="修改" href="javascript:;" onClick="xiugai('{:U('Admin/Hotnew/editCategory',array('cid'=>$vo['cid']))}','修改产品类别')"  class="ml-5" style="text-decoration:none"><i class="icon-edit"></i></a> </td>
      </tr>
    </volist>
    </tbody>
  </table>
 <div id="pageNav" class="pageNav"> {$page}</div>
   </div>
 </div>
</div>
</form>
<script type="text/javascript" src="../Public/js/jquery.min.js"></script>
<script type="text/javascript" src="App/Home/View/Public/layer/layer.js"></script>
<script type="text/javascript" src="../Public/js/H-ui.admin.js"></script>  

<script>
function tianjia(url,title){
layer.open({
            skin:'layui-layer-molv',
          type: 2,
          maxmin: true, 
           shadeClose: true,
              // shade: false,
          // skin: 'layui-layer-rim', //加上边框
          area: ['500px', '300px'], //宽高
          title:title,
          content: [url],
          end: function(){
               location.replace(location.href);
            }
        
        });
}

function xiugai(url,title){
layer.open({
           skin:'layui-layer-molv',
          type: 2,
          maxmin: true, 
           shadeClose: true,
              // shade: false,
          // skin: 'layui-layer-rim', //加上边框
          area: ['500px', '300px'], //宽高
          title:title,
          content: [url],
          end: function(){
               location.replace(location.href);
            }
        
        });
}

</script>

<script type="text/javascript">
var url="{:U('Admin/Hotnew/delCategory')}";
$(function(){
	$(".l").click(function(){
		if($("tbody input[type='checkbox']:checked").size()==0){
            lankoyCMS.alert("请先选择你要删除的记录吧");
            return false;
        }
	   layer.confirm('确认要删除吗？',{skin:'layui-layer-molv',title:'商品分类',icon:6,anim: 4},function(index){
          form1.action=url;
          form1.submit();
	  });

  });
});

</script>


</body>
</html>